﻿function sendMessage(message){
    art.dialog({time: 2, content: message,lock: true,fixed:true,opacity:0.1});
}
function btnSendMessage(message){
    art.dialog.alert(message);
}
function customButton(message,btnTitle1,url,btnTitle2){
    art.dialog({
        id: 'testID',
        content: message,
        lock: true,
        fixed:true,
        opacity:0.1,
        button: [
            {
                name: btnTitle1,
                callback: function () {
                     window.location=url;
                    return false;
                },
                focus: true
            },
            {
                name: btnTitle2,
                callback: function () {
                }
            }
        ]
    });
}
function customButtonShoppingCart(message,btnTitle1,sid,btnTitle2){
    art.dialog({
        id: 'testID',
        content: message,
        lock: true,
        fixed:true,
        opacity:0.1,
        button: [
            {
                name: btnTitle1,
                callback: function () {
                    deleteShoppingCart(sid);
                },
                focus: true
            },
            {
                name: btnTitle2,
                callback: function () {
                }
            }
        ]
    });
}
function confirmMessage(message,url){
    art.dialog.confirm(message, function(){
        window.location.href=url;
        return true;
    }, function(){
        art.dialog.tips('你取消了操作');
    });
}
